package com.mtsmda.testRun;

import java.net.MalformedURLException;
import java.net.URL;
import java.util.GregorianCalendar;

import javax.xml.namespace.QName;
import javax.xml.ws.Service;

import com.mtsmda.daoI.CustomerDAOI;
import com.mtsmda.is.admin.domain.Customer;

public class RunTest {

	public static void main(String[] args) throws MalformedURLException {

		/*
		 * try { URL wsdlUrl = new
		 * URL("http://localhost:9798/wsr/customer?wsdl"); QName qName = new
		 * QName("http://daoImpl.mtsmda.com/", "CustomerDAOImplService");
		 * 
		 * Service service = Service.create(wsdlUrl, qName); CustomerDAOI
		 * customerDAOI2 = service.getPort(CustomerDAOI.class);
		 * 
		 * Customer customer = customerDAOI2.getCustomer(1);
		 * System.out.print(customer);
		 * System.out.print(customer.getEmailPost());
		 * 
		 * 
		 * Customer customer1 = new Customer(); customer1 .setDateOfBirth( new
		 * GregorianCalendar(1986, 02, 07) .getGregorianChange())
		 * .setEmailPost("denisov.denis@mail.ru") .setFirstName("Denisov")
		 * .setGender(Customer.Gender.GENDER_M) .setLastName("Denis")
		 * .setMiddleName("Denisovici") .setMobilePhoneNumber("069863246")
		 * .setOrganisationOrPerson( Customer.OrganisationOrPerson.PERSON)
		 * .setPhoneNumber("02359621").setPostIndex("md9624");
		 * 
		 * System.out.println(customerDAOI2.insertCustomer(customer1));
		 * 
		 * } catch (Exception e) { e.printStackTrace(); }
		 */

		/*
		 * CustomerDAOImpl customerDAOI = new CustomerDAOImpl(); List<Customer>
		 * allCustomers = customerDAOI.getAllCustomers();
		 * System.out.println(allCustomers);
		 * 
		 * System.out.println(customerDAOI.getCustomer(new Integer(1)));
		 * 
		 * System.out.println("-----------");
		 */

		/*
		 * URL wsdlUrl = new URL("http://localhost:9999/ws/customer?wsdl");
		 *//**
		 * targetNamespace="http://daoImpl.mtsmda.com/" service
		 * name="CustomerDAOImplService"
		 * */
		/*
		 * QName qName = new QName("http://daoImpl.mtsmda.com/",
		 * "CustomerDAOImplService");
		 * 
		 * Service service = Service.create(wsdlUrl, qName); CustomerDAOI
		 * customerDAOI2 = service.getPort(CustomerDAOI.class); Customer
		 * customer = customerDAOI2.getCustomer(new Long(1));
		 * 
		 * System.out.println();
		 * 
		 * System.out.println(customer);
		 */

	}

}